<script setup>
import { ref } from 'vue'
const open = ref(false)
</script>
<template>
    <button @click="open = true">Open Model</button>
    <div v-if="open" class="mode">
        <h1>Hello from Model</h1>
        <button @click="open = false">Close Model</button>
    </div>
</template>

<style scoped>
.mode {
    position: fixed;
    z-index: 999;
    top: 20%;
    left: 50%;
    width: 300px;
    margin-left: -150px;
    background-color: black;
    padding: 20px;
}
</style>